package com.sky.demo.repository;

import java.util.List;
import java.util.Map;

import org.realogic.cfm.persistence.query.QueryCondition;

import com.github.pagehelper.PageInfo;
import com.sky.demo.entity.EntityWarehouse;

/**
 * 仓库-DAO接口
 */
public interface EntityWarehouseDao {

	/**
	 * 新增[仓库]实体数据
	 * 
	 * @param aModel
	 *            EntityWarehouse
	 * @return int
	 */
	public int create(EntityWarehouse aModel);

	/**
	 * 修改[仓库]实体数据
	 * 
	 * @param aModel
	 *            EntityWarehouse
	 * @return int
	 */
	public int update(EntityWarehouse aModel);

	/**
	 * 按PK删除[仓库]实体数据
	 * 
	 * @param aKey
	 * @return int
	 */
	public int remove(Long aKey);

	/**
	 * 按PK读取[仓库]实体数据
	 * 
	 * @param aKey
	 * @return EntityWarehouse
	 */
	public EntityWarehouse read(Long aKey);

	/**
	 * 根据条件查询[单实体]实体数据
	 * 
	 * @param aCondition
	 *            QueryCondition
	 * @return List<EntityWarehouse>
	 */
	public List<EntityWarehouse> query(QueryCondition aCondition);

	/**
	 * 根据条件查询[仓库]实体数据
	 * 
	 * @param aCondition
	 *            条件Map参数
	 * @param aPageNo
	 *            页号
	 * @param aPageSize
	 *            页条数
	 * @return PageInfo
	 */
	public PageInfo<EntityWarehouse> query(Map<String, Object> aCondition, int aPageNo, int aPageSize);

	/**
	 * 根据条件查询[仓库]实体数据
	 * 
	 * @param aCondition
	 *            条件Map参数
	 * @return List<EntityWarehouse>
	 */
	public List<EntityWarehouse> query(Map<String, Object> aCondition);

}